﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using OOS.Application.Category.Dtos;
using OOS.Core.Category;
using OOS.Core.RelyOn;

namespace OOS.Application.Category.Services.Interfaces
{
    /// <summary>
    /// 分类管理
    /// </summary>
    public interface ICategoryBasicService
    {
        /// <summary>
        /// 新增分类
        /// </summary>
        /// <param name="categoryBasic"></param>
        /// <returns></returns>
        bool InsertCategoryBasic(CategoryBasic categoryBasic);

        /// <summary>
        /// 根据id查询分类详情
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        CategoryBasicDto SelectCategoryById(int id);

        /// <summary>
        /// 根据Id修改分类信息
        /// </summary>
        /// <param name="categoryBasic"></param>
        /// <returns></returns>
        bool UpdateCategoryBasicById(CategoryBasic categoryBasic);

        /// <summary>
        /// 根据Id删除分类信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        bool DeleteCategoryBasicById(int id);

        /// <summary>
        /// 按条件(分类名称模糊查询，分类类型精确查询)分页查询
        /// </summary>
        /// <param name="categoryBasic"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <returns></returns>
        PageResponseDto<List<CategoryBasicDto>> SelectPageByConditions(CategoryBasic categoryBasic, int pageIndex, int pageSize);
    }
}
